package com.woniuxy.vue.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.woniuxy.vue.entity.Order;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;
/**
 * @Author: linKe
 * @Date: 2021/11/23 23:22
 * @FileName: OrderMapper
 * @version: 1.0
 * @Description: 描述
 */
public interface OrderMapper extends BaseMapper<Order> {

    /**
     *
     * @param tradeNo      订单编号
     * @param state     状态
     * @param payTime   支付时间
     * @return  订单
     */
    @Update("update t_order set state = #{state},pay_time = #{payTime} where order_no = #{tradeNo}")
    int updateState(@Param("tradeNo") String tradeNo, @Param("state") int state, @Param("payTime") String payTime);
}
